import { request } from "@/utils/request.js";

export const teacherInfo = (params) => {
  return request({
    url: '/teacher/page',
    method: 'get',
    params: params
  })
}

export const teacherChange = (data) => {
  return request({
    url: '/teacher',
    method: 'put',
    data: data
  })
}

export const teacherDelete = (id) => {
  return request({
    url: `/teacher/${id}`,
    method: 'delete',
  })
}

export const teacherTreeNodes = () => {
  return request({
    url: '/teacher/tree-nodes',
    method: 'get',
  })
}

export const teacherSearch = (a) => {
  return request({
    url: '/teacher/search',
    method: 'post',
    data: a
  })
}

export const teacherAdd = (studentData) => {
  return request({
    url: '/teacher',
    method: 'post',
    data: studentData
  })
}
